{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[-2.          2.44948974  8.24621125  6.78232998  9.43398113 -5.        ]\n"
     ]
    }
   ],
   "source": [
    "import numpy as np\n",
    "values = np.array([-4, 6, 68, 46, 89, -25])\n",
    "# Square root transformation #\n",
    "sqrt_trnsf_values = np.sqrt(np.abs(values)) * np.sign(values)\n",
    "print(sqrt_trnsf_values)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[2.39789527 4.11087386 4.39444915 5.30330491]\n"
     ]
    }
   ],
   "source": [
    "values = np.array([10, 60, 80, 200])\n",
    "#log transformation #\n",
    "log_trnsf_values = np.log(1+values)\n",
    "print(log_trnsf_values)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
